package com.example.myui.adapter;

import android.content.Context;
import android.support.annotation.Nullable;
import android.util.Log;

import com.chad.library.adapter.base.BaseQuickAdapter;
import com.chad.library.adapter.base.BaseViewHolder;
import com.example.myui.R;
import com.example.myui.model.SchoolModel;

import java.util.List;

public class InnerAdapter extends BaseQuickAdapter<SchoolModel, BaseViewHolder> {
    private Context mContext;

    public InnerAdapter(Context context, @Nullable List<SchoolModel> data) {
        super(R.layout.item_type_name, data);
        this.mContext = context;
        Log.i(TAG, "InnerAdapter: " + data.size());
    }

    @Override
    protected void convert(BaseViewHolder holder, SchoolModel item) {
        holder.setText(R.id.tv_name, item.getName());
        holder.setText(R.id.tv_time, item.getTime());
    }
}
